import { PRODUCT_TYPES_MAPS } from '@/constants/commodity';

const PRODUCT_TYPES_OPTIONS = [
  PRODUCT_TYPES_MAPS.TEMP,
  PRODUCT_TYPES_MAPS.POTENTIAL
]

export const FORM_ITEMS = [
  {
    prop: 'skuNo',
    label: 'SKU编码',
    type: 'input'
  },
  {
    prop: 'productName',
    label: '商品名称',
    type: 'input'
  },
  {
    prop: 'supplyNo',
    label: '供应商',
    type: 'slot',
    slotName: 'selectSupplier',
  },
  {
    prop: 'provinceCode',
    label: '省',
    type: 'select',
    clearable: true,
    options: []
  },
  {
    prop: 'enumTempProduct',
    label: '商品大类',
    type: 'select',
    clearable: true,
    options: PRODUCT_TYPES_OPTIONS
  }
]

export const TABLE_COLUMNS = [
  {
    title: '商品大类',
    key: 'enumTempProductStr'
  },
  {
    title: '四级类编码',
    key: 'categoryNo'
  },
  {
    title: '四级类名称',
    key: 'categoryName'
  },
  {
    title: 'SKU编码',
    key: 'skuNo',
  },
  {
    title: '商品名称',
    key: 'productName'
  },
  {
    title: '品牌',
    key: 'brandName'
  },
  {
    title: '系列',
    key: 'seriesName'
  },
  {
    title: '规格',
    key: 'specModel'
  },
  {
    title: '计量单位',
    key: 'unitName',
  },
  {
    title: '供应商编码',
    key: 'supplyNo'
  },
  {
    title: '供应商名称',
    key: 'supplyName',
  },
  {
    title: '省',
    key: 'provinceName'
  },
  {
    title: '进价',
    key: 'purchasePrice'
  },
  {
    title: '成本价',
    key: 'costPrice'
  },
  {
    title: '主成本价',
    key: 'mainSupCostPrice'
  },
  {
    title: '售价',
    key: 'salePrice',
  },
  {
    title: '加价率来源',
    key: 'priceAddRateSourceStr'
  },
  {
    title: '加价率',
    key: 'priceAddRate'
  },
  {
    title: '价格有效期',
    key: 'priceExpiration'
  },
  {
    title: '价格来源',
    key: 'priceSourceStr',
  },
  {
    title: '是否中标',
    key: 'bidderFlagStr'
  },
  {
    title: '更新时间',
    key: 'opeTime'
  },
]
